import React, { useMemo } from 'react';
import CouponBanner from '../CouponBanner';
import moment from 'moment';
import './demo.css'

const Demo=()=> {
  const deadline = useMemo(
    () =>
      moment()
        .add(0, 's')
        .add(0, 'm')
        .add(24, 'h')
        .add(0, 'd')
        .format('YYYY-MM-DD HH:mm:ss'),
    [],
  );
  const { hour, minute, second } = CouponBanner({

    deadline,
  });

  return <div className='nav'>
    <div className='navbar'>
    {`${hour} h ${minute} m ${second} s `}
    </div>
  </div>
};

export default Demo;
